Integrand size = 23, antiderivative size = 37 \[ \int \frac {1+a x}{\sqrt {a x} \sqrt {1-a x}} \, dx=-\frac {\sqrt {a x} \sqrt {1-a x}}{a}-\frac {3 \arcsin (1-2 a x)}{2 a} \]
[Out]
Time = 0.01 (sec) , antiderivative size = 37, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {81, 55, 633, 222} \[ \int \frac {1+a x}{\sqrt {a x} \sqrt {1-a x}} \, dx=-\frac {3 \arcsin (1-2 a x)}{2 a}-\frac {\sqrt {a x} \sqrt {1-a x}}{a} \]
[In]
[Out]
Rule 55
Rule 81
Rule 222
Rule 633
Rubi steps \begin{align*} \text {integral}& = -\frac {\sqrt {a x} \sqrt {1-a x}}{a}+\frac {3}{2} \int \frac {1}{\sqrt {a x} \sqrt {1-a x}} \, dx \\ & = -\frac {\sqrt {a x} \sqrt {1-a x}}{a}+\frac {3}{2} \int \frac {1}{\sqrt {a x-a^2 x^2}} \, dx \\ & = -\frac {\sqrt {a x} \sqrt {1-a x}}{a}-\frac {3 \text {Subst}\left (\int \frac {1}{\sqrt {1-\frac {x^2}{a^2}}} \, dx,x,a-2 a^2 x\right )}{2 a^2} \\ & = -\frac {\sqrt {a x} \sqrt {1-a x}}{a}-\frac {3 \sin ^{-1}(1-2 a x)}{2 a} \\ \end{align*}
Leaf count is larger than twice the leaf count of optimal. \(75\) vs. \(2(37)=74\).
Time = 0.11 (sec) , antiderivative size = 75, normalized size of antiderivative = 2.03 \[ \int \frac {1+a x}{\sqrt {a x} \sqrt {1-a x}} \, dx=\frac {\sqrt {a} x (-1+a x)+6 \sqrt {x} \sqrt {1-a x} \arctan \left (\frac {\sqrt {a} \sqrt {x}}{-1+\sqrt {1-a x}}\right )}{\sqrt {a} \sqrt {-a x (-1+a x)}} \]
[In]
[Out]
Result contains higher order function than in optimal. Order 9 vs. order 3.
Time = 1.54 (sec) , antiderivative size = 70, normalized size of antiderivative = 1.89
method | result | size |
default | \(-\frac {\sqrt {-a x +1}\, x \left (2 \,\operatorname {csgn}\left (a \right ) \sqrt {-x \left (a x -1\right ) a}-3 \arctan \left (\frac {\operatorname {csgn}\left (a \right ) \left (2 a x -1\right )}{2 \sqrt {-x \left (a x -1\right ) a}}\right )\right ) \operatorname {csgn}\left (a \right )}{2 \sqrt {a x}\, \sqrt {-x \left (a x -1\right ) a}}\) | \(70\) |
meijerg | \(-\frac {\sqrt {x}\, \left (-\frac {\sqrt {\pi }\, \sqrt {x}\, \left (-a \right )^{\frac {3}{2}} \sqrt {-a x +1}}{a}+\frac {\sqrt {\pi }\, \left (-a \right )^{\frac {3}{2}} \arcsin \left (\sqrt {a}\, \sqrt {x}\right )}{a^{\frac {3}{2}}}\right )}{\sqrt {-a}\, \sqrt {a x}\, \sqrt {\pi }}+\frac {2 \sqrt {x}\, \arcsin \left (\sqrt {a}\, \sqrt {x}\right )}{\sqrt {a}\, \sqrt {a x}}\) | \(86\) |
risch | \(\frac {x \left (a x -1\right ) \sqrt {a x \left (-a x +1\right )}}{\sqrt {-x \left (a x -1\right ) a}\, \sqrt {a x}\, \sqrt {-a x +1}}+\frac {3 \arctan \left (\frac {\sqrt {a^{2}}\, \left (x -\frac {1}{2 a}\right )}{\sqrt {-a^{2} x^{2}+a x}}\right ) \sqrt {a x \left (-a x +1\right )}}{2 \sqrt {a^{2}}\, \sqrt {a x}\, \sqrt {-a x +1}}\) | \(103\) |
[In]
[Out]
none
Time = 0.25 (sec) , antiderivative size = 43, normalized size of antiderivative = 1.16 \[ \int \frac {1+a x}{\sqrt {a x} \sqrt {1-a x}} \, dx=-\frac {\sqrt {a x} \sqrt {-a x + 1} + 3 \, \arctan \left (\frac {\sqrt {a x} \sqrt {-a x + 1}}{a x}\right )}{a} \]
[In]
[Out]
Result contains complex when optimal does not.
Time = 2.69 (sec) , antiderivative size = 133, normalized size of antiderivative = 3.59 \[ \int \frac {1+a x}{\sqrt {a x} \sqrt {1-a x}} \, dx=a \left (\begin {cases} - \frac {i \operatorname {acosh}{\left (\sqrt {a} \sqrt {x} \right )}}{a^{2}} - \frac {i \sqrt {x} \sqrt {a x - 1}}{a^{\frac {3}{2}}} & \text {for}\: \left |{a x}\right | > 1 \\\frac {\operatorname {asin}{\left (\sqrt {a} \sqrt {x} \right )}}{a^{2}} + \frac {x^{\frac {3}{2}}}{\sqrt {a} \sqrt {- a x + 1}} - \frac {\sqrt {x}}{a^{\frac {3}{2}} \sqrt {- a x + 1}} & \text {otherwise} \end {cases}\right ) + \begin {cases} - \frac {2 i \operatorname {acosh}{\left (\sqrt {a} \sqrt {x} \right )}}{a} & \text {for}\: \left |{a x}\right | > 1 \\\frac {2 \operatorname {asin}{\left (\sqrt {a} \sqrt {x} \right )}}{a} & \text {otherwise} \end {cases} \]
[In]
[Out]
none
Time = 0.29 (sec) , antiderivative size = 41, normalized size of antiderivative = 1.11 \[ \int \frac {1+a x}{\sqrt {a x} \sqrt {1-a x}} \, dx=-\frac {3 \, \arcsin \left (-\frac {2 \, a^{2} x - a}{a}\right )}{2 \, a} - \frac {\sqrt {-a^{2} x^{2} + a x}}{a} \]
[In]
[Out]
none
Time = 0.28 (sec) , antiderivative size = 28, normalized size of antiderivative = 0.76 \[ \int \frac {1+a x}{\sqrt {a x} \sqrt {1-a x}} \, dx=-\frac {\sqrt {a x} \sqrt {-a x + 1} - 3 \, \arcsin \left (\sqrt {a x}\right )}{a} \]
[In]
[Out]
Time = 3.75 (sec) , antiderivative size = 118, normalized size of antiderivative = 3.19 \[ \int \frac {1+a x}{\sqrt {a x} \sqrt {1-a x}} \, dx=\frac {2\,\mathrm {atan}\left (\frac {\sqrt {a\,x}}{\sqrt {1-a\,x}-1}\right )}{a}-\frac {4\,\mathrm {atan}\left (\frac {a\,\left (\sqrt {1-a\,x}-1\right )}{\sqrt {a\,x}\,\sqrt {a^2}}\right )}{\sqrt {a^2}}-\frac {\frac {2\,\sqrt {a\,x}}{\sqrt {1-a\,x}-1}-\frac {2\,{\left (a\,x\right )}^{3/2}}{{\left (\sqrt {1-a\,x}-1\right )}^3}}{a\,{\left (\frac {a\,x}{{\left (\sqrt {1-a\,x}-1\right )}^2}+1\right )}^2} \]
[In]
[Out]